/*
 * Copyright (c) 2010 CCX(China) Co.,Ltd. All Rights Reserved.
 *
 * This software is the confidential and proprietary information of
 * CCX(China) Co.,Ltd. ("Confidential Information").
 * It may not be copied or reproduced in any manner without the express 
 * written permission of CCX(China) Co.,Ltd.
 *
 * Author: zhaoshujin
 * Date: 2011-6-7 上午11:27:07
 */
package com.hash.ketama;

/**
 * @author zhaoshujin
 *
 */
public class Node {   
	  
    private String nodeName;   
       
    Node(String name) {   
        this.nodeName = name;   
    }   
       
    public String getName() {   
        return this.nodeName;   
    }   
       
    public String toString() {   
        return this.nodeName;   
    }   
       
    public boolean equals(Object obj) {   
        if (obj instanceof Node) {   
            return ((Node) obj).nodeName.equals(this.nodeName);   
        }   
           
        return false;   
    }   
       
    public int hashCode() {   
        return this.nodeName.hashCode();   
    }   
}  
